package edu.hawaii.myisern.action;

import java.util.ArrayList;
import java.util.List;
import net.sourceforge.stripes.validation.Validate;
import edu.hawaii.myisern.model.User;

/**
 * Provides a web interface for the MyIsern application.
 * 
 * @author Philip Johnson
 */
public class IndexActionBean extends MyIsernActionBean {

  @Validate(required = true)
  private String username;

  @Validate(required = true)
  private String password;

  private List<User> users = new ArrayList<User>();

  /**
   * Populates user password list.
   */
  public IndexActionBean() {
    users.add(new User("username", "password"));
  }

  /**
   * The username of the user trying to log in.
   * 
   * @param username user.
   * 
   */
  public void setUsername(String username) {
    this.username = username;
  }

  /**
   * The username of the user trying to log in.
   * 
   * @return username user
   */
  public String getUsername() {
    return username;
  }

  /**
   * The password of the user trying to log in.
   * 
   * @param password pw
   */
  public void setPassword(String password) {
    this.password = password;
  }

  /**
   * The password of the user trying to log in.
   * 
   * @return password pw
   */
  public String getPassword() {
    return password;
  }
}
